cmake_path(GET CMAKE_CURRENT_SOURCE_DIR STEM ModuleName)
project(${ModuleName})

set(CMAKE_POSITION_INDEPENDENT_CODE ON)

file(GLOB_RECURSE sources ./src/*.cc ./src/*.h)

add_library(${PROJECT_NAME} SHARED
        ${sources}
)

target_include_directories(${PROJECT_NAME}
        PUBLIC include
)

string(TOUPPER ${PROJECT_NAME}_MODULE_LIB ModuleExport)
target_compile_definitions(${PROJECT_NAME}
        PRIVATE "${ModuleExport}"
)

target_link_libraries(${PROJECT_NAME}
        PUBLIC Qt::Core
        PRIVATE pugixml
)
